﻿var fs = require('fs');
var watcher = fs.watch(__dirname + "/input2.txt",function(event,filename){
})

watcher.on('change',function(event,filename){
	console.log(filename + "发生变化")
	console.log(event)
})

setTimeout(()=>{
	console.log('关闭')
	watcher.close()
	console.log("关闭wacth")
},9000)

